# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=hidattack
pkgver=0.1
pkgrel=6
groups=('blackarch' 'blackarch-bluetooth')
pkgdesc='HID Attack (attacking HID host implementations).'
url='http://mulliner.org/bluetooth/hidattack.php'
license=('GPL')
arch=('x86_64' 'aarch64')
makedepends=('gcc')
depends=('bluez' 'openobex')
source=("http://www.mulliner.org/bluetooth/${pkgname}${pkgver//./}.tar.gz")
sha512sums=('78865a5cdd3c38f0df6246003f219d6183c1b8e2279055ff3e972ae4b74359bdc096a4837615882f123e679750d23456848eedac119f4c51dbf9c01a54bdc2d4')

build() {
  cd "${pkgname}${pkgver//./}"

  make CFLAGS="$CFLAGS"
}

package() {
  cd "${pkgname}${pkgver//./}"

  install -Dm 755 $pkgname "$pkgdir/usr/bin/$pkgname"
  install -Dm 644 -t "$pkgdir/usr/share/$pkgname/" README
  install -Dm 644 ha.inp "$pkgdir/usr/share/$pkgname/ha.inp"
}

